package com.iqik.main;

import com.iqik.client.RPCClient;
import com.iqik.common.UserService;

public class ClientBoot {

    private static final String PROVIDER_NAME = "UserService#sayHello#";

    public static void main(String[] args) throws InterruptedException {
        // 1. 创建代理对象
        UserService service = (UserService) RPCClient.createPoxy(UserService.class, PROVIDER_NAME);
        // 2。 循环给服务器写数据
        while (true) {
            String iqik = service.sayHello("iqik");
            System.out.println(iqik);
            Thread.sleep(2000);
        }
    }
}
